#ifndef __VM_CPU__
#define __VM_CPU__

namespace xm
{

	enum cpu_mode_t
	{
		RealMode16,			// 
		ProtectMode32,		// 4K PAGING, 
		LongMode64,			// 4K PAGING
	};

	typedef void *	hram_t;

	class qemu_cpu_t
	{
	public:
		virtual long	init( cpu_mode_t mode, void * userdata ) { return 0; }
		virtual hram_t	ram_insert( vxpma_t pma, uint32_t size, void* hptr ){ return 0; }
		virtual long	ram_remove( hram_t h ){ return 0; }
		virtual vxerr_t	reg_get( vxr_t id, vxlong_t* v){ return VXERR_OK; }
		virtual vxerr_t	reg_set( vxr_t id, vxlong_t v){ return VXERR_OK; }
		virtual vxerr_t	ctx_get( void * context ) { return VXERR_OK; }
		virtual vxerr_t	ctx_set( void * context ) { return VXERR_OK; }
		virtual vxerr_t segcc_set( vxr_t id, uint16_t sel, vxvma_t va_base, uint32_t limit, uint32_t flags ){ return VXERR_OK; }
		virtual vxerr_t xdt_load( vxr_t id, vxvma_t base, uint32_t limit ){ return VXERR_OK; }
		virtual vxerr_t exec_go(VXResult*){ return VXERR_OK; }
		virtual vxerr_t exec_step(VXResult*){ return VXERR_OK; }
		virtual vxerr_t cc_invalid( vxpma_t gpma, size_t len ){ return VXERR_OK; }
		virtual vxerr_t tlb_flush( vxpma_t vma ){ return VXERR_OK; }
	};
//vxerr_t vx64_insert_bp(vxvma_t gvma);
//vxerr_t vx64_insert_wp(vxvma_t gvma, vxvma_t size, VXWatchPointType type);
//vxerr_t vx64_remove_bp(vxvma_t gvma);
//vxerr_t vx64_remove_all_bps();
//vxerr_t vx64_remove_wp(vxvma_t gvma, vxvma_t size, VXWatchPointType type);
//vxerr_t vx64_remove_all_wps();
//vxerr_t vx64_query_bps(vxvma_t* bps, int* len);
//vxerr_t vx64_query_wps(VXWatchPoint* wps, int* len);

};



#endif